package proxy;

public class ProxySubject {
    private Subject subject;

    public ProxySubject(Subject subject) {
        this.subject = subject;
    }

    public void proxy(){
        this.sale();
        this.subject.sellBook();
        this.give();
    }

    private void sale(){
        System.out.println("打折");
    }

    private void give(){
        System.out.println("赠送代金券");
    }
}
